package org.example.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.time.LocalDateTime;


@Data
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@TableName("tb_activity_order")
public class ActivityOrder implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 主键
     */
    @TableId(value = "id", type = IdType.INPUT)
    @JsonSerialize(using= ToStringSerializer.class)
    private Long id;

    /**
     * 报名的用户id
     */
    private Long userId;

    /**
     * 参与的活动id
     */
    private Long activityId;

    /**
     订单状态，1：已报名；2：已取消报名；3：已参与；
     */
    private Integer status;



    /**
     * 活动参与时间
     */
    private LocalDateTime activityStartTime;


    /**
     * 活动参与时间
     */
    private LocalDateTime activityEndTime;





    /**
     * 报名时间
     */
    private LocalDateTime createTime;
    /**
     * 取消参与时间
     */
    private LocalDateTime cancelTime;
    @TableField(exist = false)
    private String images;

    @TableField(exist = false)
    private String title;




}
